﻿<!--#include file="const.inc"-->
<%
'====================================================================
' 感谢使用晴天3G智能建站系统..
' 作者:梁永强.QQ:766750857
' 官方网址:wap.qt3g.com
' 声明:软件版权归作者所有,没有经过作者本人同意不得非法破解和传播本程序
'====================================================================
%>
<%
dim id
		id=Request.QueryString("id")
		if not isnumeric(id) then id=0
		if id="" then id=0
		id=clng(id)
if sid="Null" then
Response.Redirect "/login.asp?sid=" & sidd & "&url=/articview.asp?id="&id
Response.end
end if
IF Request.QueryString("Action")="login" Then
	call loginn
else
	call index
end if
end Function

Function index
dim url,id
		url=Request.QueryString("url")

		id=Request.QueryString("id")
		if not isnumeric(id) then id=0
		if id="" then id=0
		id=clng(id)
select case v
case "0"
we0="<br/>"
hr="-------------<br/>"
%>
<card title="下载文章"><p align="<%=qingtian.px%>">
<%
case "1"
hr=""
zi="<span style=""color:#FF5500"">"
zi0="</span>"
we="<div class=""footer"">"
sou="<div class=""block4"">"
dao="<div class=""navi"">"
we0="</div>"
%>
<title>下载文章</title>
</head>
<body>
<!--#include virtual="/css.inc"-->
<%

End Select
%><%=qingtian.qingsav("69")%><%=we%><%if qingtian.vip(qingtian.nid)="VIP会员" then%>
你好,由于你是本站VIP会员可以免费下载此资源,
<%else%>
下载此文章需花费<%=qingtian.confff("bit")%><%=qingtian.bi%>(<%=zi%>成为VIP会员，可以终身免币下载，还可享受更多特权<%=zi0%>),
<%end if%>
确定要下载吗？<%=we0%><%=sou%>
<a href='downtxt.asp?Action=login&amp;url=<%=url%>&amp;id=<%=id%>&amp;sid=<%=sidd%>'>是的</a>|<a href='/articview.asp?url=<%=url%>&amp;id=<%=id%>&amp;sid=<%=sidd%>'>取消</a><%=we0%>
<%=qingtian.qingsav("70")%>
<%=we%><a href='/articview.asp?id=<%=id%>&amp;sid=<%=sidd%>'>返回上级</a><%=we0%>

<%
End Function

Function loginn
dim url,id,name,content,strr,fs,xTextFile,sql,rs,tip,yd,path,txt,re,nid
		url=Request.QueryString("url")
		id=Request.QueryString("id")
		if not isnumeric(id) then id=0
		if id="" then id=0
		id=clng(id)
select case v
case "0"
we0="<br/>"
hr="-------------<br/>"
%>
<card title="下载文章"><p align="<%=qingtian.px%>">
<%
case "1"
hr=""
zi="<span style=""color:#FF5500"">"
zi0="</span>"
we="<div class=""footer"">"
sou="<div class=""block4"">"
dao="<div class=""navi"">"
we0="</div>"
%>
<title>下载文章</title>
</head>
<body>
<!--#include virtual="/css.inc"-->
<%

End Select
if url="" then 
tip="出错了！你下载的文章不存在！"
errss=0
end if
If conn.execute("select money from [qingtian_user] where sid='"&qingtian.Formatsid(sid)&"'")("money")<qingtian.confff("bit") Then 
                        Tip="出错了！你的"&qingtian.bi&"不够哦！"
                        errss=0
end if
if errss<>"0" then
if qingtian.vip(qingtian.nid)<>"VIP会员" then
qingtian.payy("-"&qingtian.confff("bit"))
strr=""&qingtian.nid&"tt你好,你浏览的文章下载成功,系统自动扣除"&qingtian.confff("bit")&""&qingtian.bi&"!(url=/articview.asp?id="&id&"&url="&url&"&sid=[sid])点此进入查看文章(/url)!"
qingtian.addnfo(strr)
end if
Response.Redirect url
else
Response.Write we&tip&we0
%>
<%=sou%><a href='/articview.asp?id=<%=id%>&amp;sid=<%=sidd%>'>返回上级</a><%=we0%>
<%

end if
end function
%>